home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part1 / 2184 < prev    next >
Encoding:
Internet Message Format  |  1996-08-06  |  811 b 

  1. Path: myers1-006.resnet.drexel.edu!user
  2. From: st95h6e9@dunx1.ocs.drexel.edu (Luke Cassady-Dorion)
  3. Newsgroups: comp.lang.c++
  4. Subject: Initalizing variables in a for loop
  5. Date: Mon, 15 Jan 1996 20:22:39 -0500
  6. Organization: Drexel University, Philly, PA
  7. Message-ID: <st95h6e9-1501962022390001@myers1-006.resnet.drexel.edu>
  8. NNTP-Posting-Host: myers1-006.resnet.drexel.edu
  9.  
  10. When initalizing a variable in a for loop as in the example below does the
  11. compiler free up the memory allocated to that variable after the loop
  12. exits, thus making the variable unuseable by other parts of the function,
  13. or its it retined??
  14.  
  15.  
  16.    for (int i=0; i < some_value, i++)
  17.  
  18. ------
  19. Luke Cassady-Dorion
  20. Drexel University, Philly, PA
  21. College of Engineering
  22.  
  23. st95h6e9@dunx1.ocs.drexel.edu
  24. http://myers1-006.resnet.drexel.edu
  25.  
  26. Taurus. :)
  27.  
  28.  
  29.  
  30.